package com.viewpagertext.json;

import androidx.room.Entity;
import androidx.room.Ignore;
import androidx.room.PrimaryKey;

@Entity(tableName = "starred_songs")
public class StarredSong {
    @PrimaryKey(autoGenerate = true)
    private int id;
    private String singer;
    private String name;
    private String songId;
    private long time;

    @Ignore
    public StarredSong() {

    }

    public StarredSong(String singer, String name, String songId, long time, String pic, String lrc, String url) {
        this.singer = singer;
        this.name = name;
        this.songId = songId;
        this.time = time;
        this.pic = pic;
        this.lrc = lrc;
        this.url = url;
    }

    private String pic;
    private String lrc;
    private String url;
    private boolean isDownloaded;  // 是否已下载
    private String audioFilePath;  // 音频文件路径

    // Getter and setter methods
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getSinger() {
        return singer;
    }

    public void setSinger(String singer) {
        this.singer = singer;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getSongId() {
        return songId;
    }

    public void setSongId(String songId) {
        this.songId = songId;
    }

    public long getTime() {
        return time;
    }

    public void setTime(long time) {
        this.time = time;
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic;
    }

    public String getLrc() {
        return lrc;
    }

    public void setLrc(String lrc) {
        this.lrc = lrc;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public boolean isDownloaded() {
        return isDownloaded;
    }

    public void setDownloaded(boolean downloaded) {
        isDownloaded = downloaded;
    }

    public String getAudioFilePath() {
        return audioFilePath;
    }

    public void setAudioFilePath(String audioFilePath) {
        this.audioFilePath = audioFilePath;
    }
}
